<!DOCTYPE html>
<html>

	<head>
		<meta charset="utf-8" />
		<title>运营中心列表</title>
		<link rel="stylesheet" href="__OEM__/css/iconfont.css" />
		<link rel="stylesheet" href="__OEM__/css/css.css" />
		<style>
			.empty {
			    top: 40px;
			}
		</style>
	</head>

	<body>
		{include file="public/header" /}
		<div class="index_conbox">
			<div class="index_content clearfix">
				{include file="public/lefter" /}
				<div class="right">
					<!--右侧内容-->
					<div class="rigtop">
						<span class="title">运营商列表</span>
					</div>
					<div class="indrig_con" style="position: relative;">
						{if $Think.session.user_level==1 && $Think.session.user_type==1}
						<div class="zizh_btnbox" style="top: -58px;right:30px">
							<button class="zizh_btn" type="button"><i class="iconfont icon-jia"></i>增加运营商</button>
						</div>
						{/if}
						<div class="zizh_conbox" style="padding-top: 20px;">
							<!--选项卡内容开始-->
							<div class="zizh_con_1">
								<div class="chax_conbox">
									<div class="chax_jiegnr">
										<table class="zizh_table1 zizh_table2">
											<thead>
												<tr>
													<th>运营商</th>
													<th>省份</th>
													<th>手机号</th>													
													<th class="w_10">余额</th>
													<th>佣金</th>
													<th>鼓励金</th>
													<th width="120px">是否认证</th>
													<th width="150px">推广服务商</th>
													<th width="100px">状态</th>
													<th width="120px">创建时间</th>
													<th>操作</th>
												</tr>
											</thead>
											<tbody id="tbody">
												{volist name="list" id="ad" empty="$empty"}
												<tr>
													<td>{$ad.user_name}</td>
													<td>{$ad.province}</td>
													<td>{$ad.mobile}</td>												
													<td>
														<?php echo substr($ad['balance'],0,strlen($ad['balance'])-2)?>
													</td>
													<td>
														<?php echo substr($ad['commission'],0,strlen($ad['commission'])-2)?>
													</td>
													<td>
														<?php echo substr($ad['score'],0,strlen($ad['score']))?>
													</td>
													<td>
														{if $ad.is_verify==1}
														是
														{else/}
														否
														{/if}
													</td>
													<td>{$ad.count?$ad.count : 0}</td>
													<td>
														{if $ad.status==1}
														正常
														{else/}
														冻结
														{/if}
													</td>
													<td>{$ad.add_time|substr=0,10}</td>
													<td>
														<a onclick="open_edit('{$ad.id}')">编辑</a>
													</td>
												</tr>
												{/volist}
											</tbody>
										</table>
									</div>
								</div>
							</div>
						</div>

					</div>
				</div>
			</div>
		</div>
		{include file="public/footer" /}

	</body>
	<script>
		$(".zizh_btn").click(function() {
			layer.open({
				type: 2,
				title: '增加运营中心',
				shadeClose: true,
				shade: 0.8,
				area: ['500px', '420px'],
				content: "{:url('accounts/add_agency')}"
			});
		})

		function open_edit(id) {
			var url = 'edit_agency?id=' + id;
			layer.open({
				type: 2,
				title: '编辑运营中心',
				shadeClose: true,
				shade: 0.8,
				area: ['500px', '420px'],
				content: [url]
			});
		}
	</script>

</html>